package com.lhkj.ct.meta.admin.model.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.util.List;

/**
 * <p>
 *      角色管理传参类
 * </p>
 *
 * @author job
 * @since 2023/8/30
 */
@ApiModel(value = "分配权限", description = "分配权限传参类")
public class RoleMenusDto {

    public RoleMenusDto(String id, List<String> perms) {
        this.id = id;
        this.perms = perms;
    }

    @NotBlank(message = "角色id不能为空")
    @ApiModelProperty(value = "角色id")
    private String id;

    /**
     * 角色对应的权限id
     */
    @NotEmpty(message = "请选择角色对应的权限")
    @ApiModelProperty(value = "权限集合", dataType = "list")
    private List<String> perms;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public List<String> getPerms() {
        return perms;
    }

    public void setPerms(List<String> perms) {
        this.perms = perms;
    }
}
